package proyecto.modelo;

import java.io.Serializable;
import javax.persistence.*;

/**
 * The primary key class for the det_boleta database table.
 * 
 */
@Embeddable
public class DetBoletaPK implements Serializable {
	//default serial version id, required for serializable classes.
	private static final long serialVersionUID = 1L;

	@Column(name="co_boleta")
	private int coBoleta;

	@Column(name="co_detalle")
	private int coDetalle;

    public DetBoletaPK() {
    }
	public int getCoBoleta() {
		return this.coBoleta;
	}
	public void setCoBoleta(int coBoleta) {
		this.coBoleta = coBoleta;
	}
	public int getCoDetalle() {
		return this.coDetalle;
	}
	public void setCoDetalle(int coDetalle) {
		this.coDetalle = coDetalle;
	}

	public boolean equals(Object other) {
		if (this == other) {
			return true;
		}
		if (!(other instanceof DetBoletaPK)) {
			return false;
		}
		DetBoletaPK castOther = (DetBoletaPK)other;
		return 
			(this.coBoleta == castOther.coBoleta)
			&& (this.coDetalle == castOther.coDetalle);

    }
    
	public int hashCode() {
		final int prime = 31;
		int hash = 17;
		hash = hash * prime + this.coBoleta;
		hash = hash * prime + this.coDetalle;
		
		return hash;
    }
}